{% if page.repositories != false %}
  <link rel="stylesheet" href="/assets/css/components/repo-card.css"/>
  <!-- 仓库展示 -->
  <h3>My Popular Repositories</h3>
  {% if site.github.public_repositories != null %}
    {% assign repos = site.github.public_repositories | sort: "stargazers_count" | reverse%}
    {% for repo in repos | limit: site.side_bar_repo_limit %}
      <a href="{{ repo.html_url }}" target="_blank" class="card text-center">
        <div class="thumbnail">
          <div class="card-image geopattern" data-pattern-id="{{ repo.name }}">
            <div class="card-image-cell">
              <h3 class="card-title">
                {{ repo.name }}
              </h3>
            </div>
          </div>
          <div class="caption">
            <div class="card-description">
              <p class="card-text">{{ repo.description }}</p>
            </div>
            <div class="card-text">
              <span class="meta-info" title="{{ repo.stargazers_count }} stars">
                <span class="octicon octicon-star"></span> {{ repo.stargazers_count }}
              </span>
              <span class="meta-info" title="{{ repo.forks_count }} forks">
                <span class="octicon octicon-git-branch"></span> {{ repo.forks_count }}
              </span>
              <span class="meta-info" title="Last updated：{{ repo.updated_at }}">
                <span class="octicon octicon-clock"></span>
                <time datetime="{{ repo.updated_at }}">{{ repo.updated_at | date: '%Y-%m-%d' }}</time>
              </span>
            </div>
          </div>
        </div>
      </a>
    {% endfor %}
  {% endif %}
{% endif %}